import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/Home'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'home',
    component: HomeView
  },
  
  {
    path: '/state',
    name: 'state',
    component: () => import(/* webpackChunkName: "about" */ '../views/State')
  },
  {
    path: '/mutation',
    name: 'mutation',
    component: () => import(/* webpackChunkName: "about" */ '../views/Mutation')
  },
  {
    path: '/getters',
    name: 'getters',
    component: () => import(/* webpackChunkName: "about" */ '../views/Getters')
  },
  {
    path: '/actions',
    name: 'actions',
    component: () => import(/* webpackChunkName: "about" */ '../views/Actions')
  },
  {
    path: '/modules',
    name: 'modules',
    component: () => import(/* webpackChunkName: "about" */ '../views/Modules')
  },
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
